<script setup lang="ts">
import {StnCollapsePopBtn} from 'st-ui-vue3-navie'
import {StIconIconify} from 'st-common-ui-vue3'
import EditIcon from '@iconify-icons/tabler/edit'

/**
 * 组件参数
 */
const {
  text = '编辑',
  isText = false,
  isCollapse = false,
  isDisabled = false,
} = defineProps<{
  // 按钮文本
  text?: string;
  // 按钮是否为文本按钮
  isText?: boolean;
  // 按钮是否折叠收缩
  isCollapse?: boolean;
  // 按钮是否禁用
  isDisabled?: boolean;
}>()
</script>

<template>
  <StnCollapsePopBtn
    type="primary"
    :btn-text="text"
    :text="isText"
    :is-collapse="isCollapse"
    :btn-disabled="isDisabled"
  >
    <template #icon>
      <slot name="icon">
        <StIconIconify :icon="EditIcon" />
      </slot>
    </template>
  </StnCollapsePopBtn>
</template>

<style scoped>

</style>
